package com.explorati.design_pattern.structural.flyweight.v2;

public class Test {

	private static String colors[] = { "蓝色", "绿色", "紫色" };

	public static void main(String[] args) {
		for (int i = 0; i < 5; i++) {
			String color = colors[(int) (Math.random() * colors.length)];
			Circle circle = CircleFactory.getCircle(color);

			System.out.println(circle.calArea());
		}
	}
}
